//
// Created by 张闳 on 2021/12/4.
//

#ifndef MCOMMON_UUID_H
#define MCOMMON_UUID_H
/**
 * Copyright (c) 2018 rxi
 *
 * This library is free software; you can redistribute it and/or modify it
 * under the terms of the MIT license. See LICENSE for details.
 */

#define UUID4_VERSION "1.0.0"
#define UUID4_LEN 37

enum {
    UUID4_ESUCCESS =  0,
    UUID4_EFAILURE = -1
};

/**
 * 初始化uuid
 * @return  成功返回0，失败返回-1
 */
int  uuid4_init(void);

/**
 * 生成一个uuid串，必须先初始化过
 * @param dst   生成的uuid串,该串必须是一个函数外部定义的字符数组,长度不小于36字节
 */
void uuid4_generate(char *dst);


#endif //MCOMMON_UUID_H
